package com.artnology.independence.views.operations;

import org.apache.commons.collections15.Predicate;

import com.artnology.independence.model.relationships.DVAbstractTypeRelationship;
import com.artnology.independence.model.relationships.DVReference;

public class TypeRelationshipPredicate implements Predicate<DVReference> {

	private Class<? extends DVAbstractTypeRelationship> filterRelationshipType;
	
	
	public TypeRelationshipPredicate(
			Class<? extends DVAbstractTypeRelationship> filterRelationshipType) {
		super();
		this.filterRelationshipType = filterRelationshipType;
	}


	@Override
	public boolean evaluate(DVReference relationship) {
		return !(relationship.getClass().equals(filterRelationshipType));
	}

}
